﻿namespace Pub.Class
{
    using System;

    [Serializable, EntityInfo("缓存内容实体类")]
    public class CachedItem
    {
        private object cacheData;
        private string cacheKey;
        private string cacheType;
        private DateTime endTime;
        private DateTime startTime;

        public CachedItem()
        {
        }

        public CachedItem(string key, string type)
        {
            this.CacheKey = key;
            this.CacheType = type;
        }

        [EntityInfo("内容")]
        public object CacheData
        {
            get
            {
                return this.cacheData;
            }
            set
            {
                this.cacheData = value;
            }
        }

        [EntityInfo("缓存键")]
        public string CacheKey
        {
            get
            {
                return this.cacheKey;
            }
            set
            {
                this.cacheKey = value;
            }
        }

        [EntityInfo("数据类型")]
        public string CacheType
        {
            get
            {
                return this.cacheType;
            }
            set
            {
                this.cacheType = value;
            }
        }

        [EntityInfo("结束时间")]
        public DateTime EndTime
        {
            get
            {
                return this.endTime;
            }
            set
            {
                this.endTime = value;
            }
        }

        [EntityInfo("开始时间")]
        public DateTime StartTime
        {
            get
            {
                return this.startTime;
            }
            set
            {
                this.startTime = value;
            }
        }
    }
}

